﻿using RMM.UserAdminService;
using RMM.UserAdminService.Dtos;
using System.Threading.Tasks;
using System.Web.Mvc;

namespace RMM.Web.Controllers.User
{
    public class UserController : BaseController
    {
        private readonly IUserAdminService _userAdminService;

        public UserController(IUserAdminService userAdminService)
        {
            _userAdminService = userAdminService;
        }

        AdminUserDto adminUser = new AdminUserDto();
        // GET: User
        public ActionResult Index()
        {
            return View();
        }

        //[HttpGet]
        public async Task<ActionResult> GetUserListAsync()
        {
            var users = await _userAdminService.GetUserListAsync();
            return Jsons(users);
        }


    }
}